<?php

namespace App\Exports;

use App\Services\Designer\Model\Designer;
use Maatwebsite\Excel\Concerns\FromCollection;
use Maatwebsite\Excel\Concerns\WithHeadings;

class DesignerDataExport implements FromCollection, WithHeadings
{
    public function collection()
    {
        return Designer::select('id', 'name')->get();
    }

    public function headings(): array
    {
        return [
            '设计师ID',
            '名称名称',
        ];
    }
}
